import Vue from "vue";
import VueRouter, { RouteConfig } from "vue-router";
import ButtonPage from "@/views/ButtonPage.vue";
import MsVideoPage from "@/views/MsVideoPage.vue";
import MsRowPage from "@/views/MsRowPage.vue";

import Layout from "../Layout.vue";
Vue.use(VueRouter);

const routes: Array<RouteConfig> = [
  {
    path: "/",
    name: "ButtonPage.vue",
    component: Layout,
    children: [
      {
        path: "button",
        name: "MsButton",
        component: ButtonPage,
      },
      {
        path: "video",
        name: "MsVideo",
        component: MsVideoPage,
      },
      {
        path: "row",
        name: "MsRow",
        component: MsRowPage,
      },
    ],
  },
];

const router = new VueRouter({
  routes,
});

export default router;
